package com.ruoyi.project.business.service.impl;



import java.util.List;

import com.ruoyi.common.utils.DateUtils;

import org.springframework.beans.factory.annotation.Autowired;

import org.springframework.stereotype.Service;

import com.ruoyi.project.business.mapper.BusinessSeedStoreMapper;

import com.ruoyi.project.business.domain.BusinessSeedStore;

import com.ruoyi.project.business.service.IBusinessSeedStoreService;



/**

 * 种子商城Service业务层处理

 * 

 * @author ruoyi

 * @date 2020-10-20

 */

@Service

public class BusinessSeedStoreServiceImpl implements IBusinessSeedStoreService 

{

    @Autowired

    private BusinessSeedStoreMapper businessSeedStoreMapper;



    /**

     * 查询种子商城

     * 

     * @param id 种子商城ID

     * @return 种子商城

     */

    @Override

    public BusinessSeedStore selectBusinessSeedStoreById(Long id)

    {

        return businessSeedStoreMapper.selectBusinessSeedStoreById(id);

    }



    /**

     * 查询种子商城列表

     * 

     * @param businessSeedStore 种子商城

     * @return 种子商城

     */

    @Override

    public List<BusinessSeedStore> selectBusinessSeedStoreList(BusinessSeedStore businessSeedStore)

    {

        return businessSeedStoreMapper.selectBusinessSeedStoreList(businessSeedStore);

    }



    /**

     * 新增种子商城

     * 

     * @param businessSeedStore 种子商城

     * @return 结果

     */

    @Override

    public int insertBusinessSeedStore(BusinessSeedStore businessSeedStore)

    {

        businessSeedStore.setCreateTime(DateUtils.getNowDate());

        return businessSeedStoreMapper.insertBusinessSeedStore(businessSeedStore);

    }



    /**

     * 修改种子商城

     * 

     * @param businessSeedStore 种子商城

     * @return 结果

     */

    @Override

    public int updateBusinessSeedStore(BusinessSeedStore businessSeedStore)

    {

        businessSeedStore.setUpdateTime(DateUtils.getNowDate());

        return businessSeedStoreMapper.updateBusinessSeedStore(businessSeedStore);

    }



    /**

     * 批量删除种子商城

     * 

     * @param ids 需要删除的种子商城ID

     * @return 结果

     */

    @Override

    public int deleteBusinessSeedStoreByIds(Long[] ids)

    {

        return businessSeedStoreMapper.deleteBusinessSeedStoreByIds(ids);

    }



    /**

     * 删除种子商城信息

     * 

     * @param id 种子商城ID

     * @return 结果

     */

    @Override

    public int deleteBusinessSeedStoreById(Long id)

    {

        return businessSeedStoreMapper.deleteBusinessSeedStoreById(id);

    }

}
